# Lab - Linux Kernel

- Access Hands-On Labs here [Hands-On Labs](https://kodekloud.com/topic/lab-linux-kernel-lsmod-insmod-modprobe-uname/)

To check the exact kernel version that is running in this system. 
```
$ uname -r
```

what is the kernel version in 4.15.0-88-generic?
```
Look for the first digit. In this case, it is 15
```

What is the major version number of the kernel 4.15.0-88-generic
```
Look for the second digit after the kernel version separated by a . In this case, it is 15
```

Which command would you run to print the messages generated by the kernel?
```
Type the command dmesg to see the messages.
$ dmesg
```

To list/count all block devices of type disk that are present in the system
```
Run: lsblk and count the number of disk devices.
$ lsblk
```

To check total number of **`physical cores`** in the system.
```
Run lscpu and multiply the Core(s) per socket with the number of Socket(s):
$ lscpu
```

To check total online memory
```
Run the lsmem command and look for the value of online memory
$ lsmem
```





